package com.studerb.events;

public class NetworkMonitorEvent {
    public enum EventType {
        NETWORK_UP, NETWORK_DOWN, NETWORK_ERROR
    }

    private EventType type;
    private Throwable throwable;

    public NetworkMonitorEvent(EventType eventType) {
        this.type = eventType;
    }

    public NetworkMonitorEvent(EventType eventType, Throwable throwable) {
        this.type = eventType;
        this.throwable = throwable;
    }

    public Throwable getThrowable() {
        return throwable;
    }

    public EventType getType() {
        return this.type;
    }
}
